package io.scnb.lesson001.demo27.test4;

import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.DependsOn;

@Configuration
public class MainConfig4 {
    
    @Bean   
    @DependsOn({"service2", "service3"})
    public Service1 service1() {
        return new Service1();
    }
    
    @Bean
    public Service2 service2() {
        return new Service2();
    }
    
    @Bean
    public Service3 service3() {
        return new Service3();
    }
    
}
